<?php

namespace App\Admin\Actions\Post;

use App\Models\ResumeSend;
use Encore\Admin\Actions\RowAction;
use Illuminate\Database\Eloquent\Model;

class WorkerInfo extends RowAction
{
    public $jobid;
    public $name = '查看投递工人';

    public function __construct($jobid)
    {
        $this->jobid = $jobid;
    }

    public function href()
    {
        $id = ResumeSend::where('job_id', $this->jobid)->value('id');

        return "/admin/resume_send/" . $id;
    }

}